﻿using AutoStar.ViewModel;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;

namespace AutoStar.Views
{
    /// <summary>
    /// WindowXYZ.xaml 的交互逻辑
    /// </summary>
    public partial class WindowXYZ : Window
    {
        //private WindowXYZVM VM;
        public WindowXYZ()
        {
            InitializeComponent();
            DataContext = Global.WindowXYZVM;
            this.Loaded += WindowXYZ_Loaded;
            this.Closing += WindowXYZ_Closing;
        }

        private void WindowXYZ_Loaded(object sender, RoutedEventArgs e)
        {
            Global.WindowXYZVM.Load();
        }

        private void WindowXYZ_Closing(object sender, System.ComponentModel.CancelEventArgs e)
        {
            e.Cancel = true;
            this.Hide();
        }
    }
}
